<template>
	<view class="good-faith">
		<view class="faith" v-for="(item, index) in faithArr" :key="index">
			<view class="faith-text first-item">
				<view><text class="title">业务类型：</text>{{ item.servicename }}</view>
				<view v-html="item.context"></view>
			</view>
			<view class="faith-text"><text class="title">办理大厅：</text> {{ item.officename }}</view>
			<view class="faith-text"><text class="title">预约时间：</text> {{ item.pre_book_time_a }}</view>
		</view>
		<view class="no-faith" v-if="faithArr.length === 0">
			暂无记录
		</view>
	</view>
</template>

<script>
	import { goodFaith } from '../utils/methods.js'
	export default {
		data() {
			return {
				faithArr: []
			}
		},
		methods: {
			
		},
		mounted() {
			goodFaith().then(res => {
				if(res.data.code === 0) {
					this.faithArr = res.data.data
				}
			})
		}
	}
</script>

<style lang="less">
.good-faith {
	padding: 10px 10rpx;
	box-sizing: border-box;
	.faith {
		border: 1px solid #f3f3f3;
		padding: 20rpx;
		margin-bottom: 20rpx;
		border-radius: 5px;
		.faith-text {
			margin-top: 20rpx;
			color: #5e6d82;
			.title {
				font-weight: 600;
				color: black;
			}
		}
		.first-item {
			display: flex;
			justify-content: space-between;
		}
	}
	.no-faith {
		width: 100%;
		text-align: center;
		font-weight: 600;
		padding: 40rpx;
	}
}
</style>
